package com.blog.configuration;

import java.util.Collection;
import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cache.Cache;
import org.springframework.cache.support.AbstractCacheManager;
import org.springframework.stereotype.Component;

/**
 * 多级缓存管理
 *
 * @author Joy
 * @date 2020-12-26
 */
@Component
public class MultiCacheManager extends AbstractCacheManager {


    @Autowired
    private List<Cache> caches;


    @Override
    protected Collection<? extends Cache> loadCaches() {
        return this.caches;
    }
}
